package jdbctemplate;

import org.junit.Test;
import org.springframework.jdbc.core.JdbcTemplate;
import utils.JDBCUtils;

import java.util.List;
import java.util.Map;

public class JdbcTemplateDemo1 {
    public static void main(String[] args) {
        JdbcTemplate jdt = new JdbcTemplate(JDBCUtils.getDataSource());
        String sql = "select * from account";
        List<Map<String, Object>> list = jdt.queryForList(sql);
        System.out.println(list.get(0).get("balance"));


    }
}
